'''
Created on 25.01.2012

@author: cwestphal
'''
import maya.cmds as cmds

class button:
    def getFilename(self):
        #self.name = self.name
        self.name = cmds.textFieldButtonGrp("textGrp1",query=True,text=True)
        print self.name

    def __init__(self):
        window = cmds.window()
        cmds.columnLayout()
        self.name = ''
        cmds.textFieldButtonGrp("textGrp1",label='Save Pose as:', text = self.name, buttonLabel ='Export', buttonCommand=self.getFilename)
        cmds.showWindow(window)
    
first = button()